MODULE := Boot
SUBMODULES := MBR Loader
VPATH := $(_SOURCE) $(_BUILD)
.PHONY: all
NASM_FLAGS := -I $(SOURCE)/include

all:
	New-Item -Type Directory -Force -Path $(BUILD)/$(MODULE)
	nasm $(NASM_FLAGS) $(SOURCE)/$(MODULE)/MBR.asm -o $(BUILD)/MBR.bin -l $(BUILD)/$(MODULE)/MBR.lst
	nasm $(NASM_FLAGS) $(SOURCE)/$(MODULE)/Loader.asm -o $(BUILD)/Loader.bin -l $(BUILD)/$(MODULE)/Loader.lst
	nasm $(NASM_FLAGS) $(SOURCE)/$(MODULE)/InitFAT.asm -o $(BUILD)/InitFAT.bin
	nasm $(NASM_FLAGS) $(SOURCE)/$(MODULE)/RootDir.asm -o $(BUILD)/RootDir.bin